#include "dproduct.h"

//Prorammer: Nguyen Xuan Hoai
//Function: Compute dot product of a pair of vectors in 2 dimension
//Input: axes of the vectors.
//Exception Handling: None
//Algorithm: Using dot product formula

double dotp2(double x1, double y1, double x2,double y2)
{
  return x1*y1+x2*y2;
}

//Prorammer: Nguyen Xuan Hoai
//Function: Compute dot product of a pair of vectors in 3 dimension
//Input: axes of the vectors.
//Exception Handling: None
//Algorithm: Using dot product formula

double dotp3(double x1, double y1, double x2,double y2, double x3, double y3)
{
  return x1*y1+x2*y2+x3*y3;
}
